
<!DOCTYPE HTML>
<html lang="zh-hans" >
    <head>
        <meta charset="UTF-8">
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
        <title>基本使用 · GitBook教程</title>
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="description" content="">
        <meta name="generator" content="GitBook 3.2.3">
        <meta name="author" content="nutpi">
        <meta name="identifier" content="978-0-000000-00-0" scheme="ISBN">
        
    
    <link rel="stylesheet" href="../gitbook/style.css">

    
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-splitter/splitter.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-tbfed-pagefooter/footer.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-expandable-chapters/expandable-chapters.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-chapter-fold/chapter-fold.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-back-to-top-button/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-code/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-pageview-count/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-search-plus/search.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-mind-maps/mindmaps.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-emphasize/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-anchors/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-ace/ace.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-highlight/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-fontsettings/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-theme-lou/lou.css">
                
            
        

    

    
        
        <link rel="stylesheet" href="../styles/website.css">
        
    

        
    
    
    
    <meta name="HandheldFriendly" content="true"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../gitbook/images/apple-touch-icon-precomposed-152.png">
    <link rel="shortcut icon" href="../gitbook/images/favicon.ico" type="image/x-icon">

    
    <link rel="next" href="../修改gitbook内容字体大小.html" />
    
    
    <link rel="prev" href="../安装.html" />
    

    <style>
    @media only screen and (max-width: 640px) {
        .book-header .hidden-mobile {
            display: none;
        }
    }
    </style>
    <script>
        window["gitbook-plugin-github-buttons"] = {};
    </script>

    </head>
    <body>
         
<div class="donate-modal modal">
  <div class="modal-header">
    <div>
      <span>
        <img
          id="modal-avatar"
          class="modal-avatar"
          src="assets/avatar.png"
        />
      </span>
      <span id="nickname"> Breeze </span>
      <p class="modal-close close" onclick="closeDonateModal()">×</p>
    </div>
    <div class="message">
      <div class="tip">
        <i></i>
        <span>如果本教程对你有帮助，欢迎请作者喝杯咖啡 ☕</span>
      </div>
    </div>
  </div>
  <div class="modal-content">
    <div class="modal-pay-way">
      <div id="wxpay" onclick="showDonateImg(0)">
        <input
          type="radio"
          name="pay-way"
          value="wxpay"
          class="zs-type"
          checked="checked"
        />
        <span>
          <img
            id="wxpay-logo"
            src=""
          />
        </span>
      </div>
      <div id="alipay" onclick="showDonateImg(1)">
        <input type="radio" name="pay-way" value="alipay" class="zs-type" />
        <span>
          <img
            id="alipay-logo"
            src=""
          />
        </span>
      </div>
    </div>
    <div class="modal-pay-qrcode">
      <img id="wxpay-code" src="" />
      <img
        id="alipay-code"
        src="https://luckly007.oss-cn-beijing.aliyuncs.com/img/image-20210922202843746.png"
        hidden
      />
    </div>
  </div>
</div>
<div class="mask"></div>


<div class="book">
  <div class="header-inner">
    <!-- LOGO -->
    <div class="logo"></div>
    <span class="title"></span>

    <!-- Search -->
    
<div id="book-search-input" role="search">
    <input type="text" placeholder="输入并搜索" />
</div>


    <!-- Nav -->
    <ul class="header-nav">
      <li>
        <a href="https://www.gitbook.com/" target="_blank">GitBook 官网</a>
      </li><li>
        <a href="https://www.npmjs.com/search?q=gitbook-plugin" target="_blank">插件市场</a>
      </li><li>
        <a href="https://space.bilibili.com/480883651" target="_blank">哔哩哔哩</a>
      </li><li>
        <a href="https://gitcode.com/nutpi" target="_blank">GitCode</a>
      </li>
    </ul>
  </div>

  <div class="book-summary">
    <div class="book-summary-title">文档目录</div>
     
    <nav role="navigation">


<ul class="summary">
    
    

    

    
        
        
    
        <li class="chapter " data-level="1.1" data-path="../">
            
                <a href="../">
            
                    
                    前言
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">第一部分 基础入门</li>
        
        
    
        <li class="chapter " data-level="2.1" data-path="../为什么要写博客.html">
            
                <a href="../为什么要写博客.html">
            
                    
                    为什么要写博客
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="2.2" data-path="../什么是Gitbook.html">
            
                <a href="../什么是Gitbook.html">
            
                    
                    什么是 GitBook
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="2.3" data-path="../为什么选择使用GitBook来搭建.html">
            
                <a href="../为什么选择使用GitBook来搭建.html">
            
                    
                    为什么选择 GitBook
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">第二部分 环境搭建</li>
        
        
    
        <li class="chapter " data-level="3.1" data-path="../搭建方式.html">
            
                <a href="../搭建方式.html">
            
                    
                    搭建方式介绍
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="3.2" data-path="../安装.html">
            
                <a href="../安装.html">
            
                    
                    安装 GitBook
            
                </a>
            

            
        </li>
    
        <li class="chapter active" data-level="3.3" data-path="./">
            
                <a href="./">
            
                    
                    基本使用
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.3.1" data-path="../修改gitbook内容字体大小.html">
            
                <a href="../修改gitbook内容字体大小.html">
            
                    
                    修改字体大小
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.4" data-path="../gitbookinit运行bug报错.html">
            
                <a href="../gitbookinit运行bug报错.html">
            
                    
                    常见问题解决
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">第三部分 功能定制</li>
        
        
    
        <li class="chapter " data-level="4.1" data-path="../插件安装.html">
            
                <a href="../插件安装.html">
            
                    
                    插件使用指南
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="4.2" data-path="../Gitbook主题选择.html">
            
                <a href="../Gitbook主题选择.html">
            
                    
                    主题选择
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="4.3" data-path="../插入视频.html">
            
                <a href="../插入视频.html">
            
                    
                    插入视频
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="4.4" data-path="../热加载.html">
            
                <a href="../热加载.html">
            
                    
                    热加载功能
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">第四部分 域名与部署</li>
        
        
    
        <li class="chapter " data-level="5.1" data-path="../购买域名.html">
            
                <a href="../购买域名.html">
            
                    
                    购买域名
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="5.2" data-path="../将Gitbook电子书部署到Github上.html">
            
                <a href="../将Gitbook电子书部署到Github上.html">
            
                    
                    部署到 GitHub Pages
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="5.2.1" data-path="../将域名绑定到Github上.html">
            
                <a href="../将域名绑定到Github上.html">
            
                    
                    绑定域名到 GitHub
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="5.3" data-path="../将Gitbook电子书部署到Coding上.html">
            
                <a href="../将Gitbook电子书部署到Coding上.html">
            
                    
                    部署到 Coding Pages
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="5.3.1" data-path="../将域名绑定到Coding.html">
            
                <a href="../将域名绑定到Coding.html">
            
                    
                    绑定域名到 Coding
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="5.4" data-path="../自定义域名.html">
            
                <a href="../自定义域名.html">
            
                    
                    自定义域名设置
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="5.5" data-path="../部署教程.html">
            
                <a href="../部署教程.html">
            
                    
                    部署教程
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">第五部分 扩展功能</li>
        
        
    
        <li class="chapter " data-level="6.1" data-path="../其他类似GitBook的在线文档创作平台.html">
            
                <a href="../其他类似GitBook的在线文档创作平台.html">
            
                    
                    其他文档平台对比
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="6.2" data-path="../variant.html">
            
                <a href="../variant.html">
            
                    
                    Variant 功能
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="6.3" data-path="../写书前奏.html">
            
                <a href="../写书前奏.html">
            
                    
                    写书前奏
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="6.4" data-path="../阅读更多.html">
            
                <a href="../阅读更多.html">
            
                    
                    扩展阅读
            
                </a>
            

            
        </li>
    

    
        
        <li class="header">附录</li>
        
        
    
        <li class="chapter " data-level="7.1" data-path="../结语.html">
            
                <a href="../结语.html">
            
                    
                    结语
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="7.2" data-path="../致谢.html">
            
                <a href="../致谢.html">
            
                    
                    致谢
            
                </a>
            

            
        </li>
    

    

    <li class="divider"></li>

    <li>
        <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
            本书使用 GitBook 发布
        </a>
    </li>
</ul>

</nav>
     
  </div>

  <!-- Content nav -->
  <div class="book-anchor">
    <div class="book-anchor-title"></div>

    <div class="book-anchor-body"></div>
  </div>

  <div class="book-body">
    
    <div class="body-inner">
       

<div class="book-header" role="navigation">
    

    <!-- Title -->
    <h1>
        <i class="fa fa-circle-o-notch fa-spin"></i>
        <a href=".." >基本使用</a>
    </h1>
</div>



      <div class="page-wrapper" tabindex="-1" role="main">
        <div class="page-inner">
          
<div class="search-plus" id="book-search-results">
    <div class="search-noresults">
    
          <section class="normal markdown-section">
             <h1 id="&#x57FA;&#x672C;&#x4F7F;&#x7528;"><a name="&#x57FA;&#x672C;&#x4F7F;&#x7528;" class="plugin-anchor" href="#&#x57FA;&#x672C;&#x4F7F;&#x7528;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x57FA;&#x672C;&#x4F7F;&#x7528;</h1>
<p>&#x672C;&#x8282;&#x5C06;&#x4ECB;&#x7ECD; GitBook &#x7684;&#x57FA;&#x672C;&#x4F7F;&#x7528;&#x65B9;&#x6CD5;&#xFF0C;&#x5E2E;&#x52A9;&#x4F60;&#x5FEB;&#x901F;&#x4E0A;&#x624B;&#x521B;&#x5EFA;&#x548C;&#x7BA1;&#x7406;&#x7535;&#x5B50;&#x4E66;&#x3002;</p>
<h2 id="&#x521B;&#x5EFA;&#x548C;&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;"><a name="&#x521B;&#x5EFA;&#x548C;&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;" class="plugin-anchor" href="#&#x521B;&#x5EFA;&#x548C;&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x521B;&#x5EFA;&#x548C;&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;</h2>
<h3 id="1-&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;&#x76EE;&#x5F55;"><a name="1-&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;&#x76EE;&#x5F55;" class="plugin-anchor" href="#1-&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;&#x76EE;&#x5F55;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;&#x76EE;&#x5F55;</h3>
<p>&#x5728;&#x4F60;&#x7684;&#x9879;&#x76EE;&#x76EE;&#x5F55;&#x4E2D;&#x8FD0;&#x884C;&#xFF1A;</p>
<pre><code class="lang-bash">gitbook init
</code></pre>
<p>&#x8FD9;&#x4E2A;&#x547D;&#x4EE4;&#x4F1A;&#x521B;&#x5EFA;&#x4E24;&#x4E2A;&#x5FC5;&#x987B;&#x7684;&#x6587;&#x4EF6;&#xFF1A;</p>
<ul>
<li><strong><code>README.md</code></strong>&#xFF1A;&#x4E66;&#x7C4D;&#x7684;&#x7B80;&#x5355;&#x4ECB;&#x7ECD;&#x548C;&#x9996;&#x9875;&#x5185;&#x5BB9;</li>
<li><strong><code>SUMMARY.md</code></strong>&#xFF1A;&#x4E66;&#x7C4D;&#x7684;&#x76EE;&#x5F55;&#x7ED3;&#x6784;</li>
</ul>
<h3 id="2-&#x76EE;&#x5F55;&#x7ED3;&#x6784;&#x793A;&#x4F8B;"><a name="2-&#x76EE;&#x5F55;&#x7ED3;&#x6784;&#x793A;&#x4F8B;" class="plugin-anchor" href="#2-&#x76EE;&#x5F55;&#x7ED3;&#x6784;&#x793A;&#x4F8B;"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x76EE;&#x5F55;&#x7ED3;&#x6784;&#x793A;&#x4F8B;</h3>
<p>&#x521D;&#x59CB;&#x5316;&#x540E;&#x7684;&#x76EE;&#x5F55;&#x7ED3;&#x6784;&#x5982;&#x4E0B;&#xFF1A;</p>
<pre><code>my-book/
&#x251C;&#x2500;&#x2500; README.md      # &#x4E66;&#x7C4D;&#x4ECB;&#x7ECD;
&#x251C;&#x2500;&#x2500; SUMMARY.md     # &#x76EE;&#x5F55;&#x7ED3;&#x6784;
&#x2514;&#x2500;&#x2500; chapter1/      # &#x7AE0;&#x8282;&#x76EE;&#x5F55;&#xFF08;&#x53EF;&#x9009;&#xFF09;
    &#x2514;&#x2500;&#x2500; README.md
</code></pre><h2 id="&#x672C;&#x5730;&#x9884;&#x89C8;&#x548C;&#x5F00;&#x53D1;"><a name="&#x672C;&#x5730;&#x9884;&#x89C8;&#x548C;&#x5F00;&#x53D1;" class="plugin-anchor" href="#&#x672C;&#x5730;&#x9884;&#x89C8;&#x548C;&#x5F00;&#x53D1;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x672C;&#x5730;&#x9884;&#x89C8;&#x548C;&#x5F00;&#x53D1;</h2>
<h3 id="1-&#x542F;&#x52A8;&#x672C;&#x5730;&#x670D;&#x52A1;"><a name="1-&#x542F;&#x52A8;&#x672C;&#x5730;&#x670D;&#x52A1;" class="plugin-anchor" href="#1-&#x542F;&#x52A8;&#x672C;&#x5730;&#x670D;&#x52A1;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x542F;&#x52A8;&#x672C;&#x5730;&#x670D;&#x52A1;</h3>
<p>&#x8FD0;&#x884C;&#x4E00;&#x4E2A;&#x672C;&#x5730; web &#x670D;&#x52A1;&#xFF0C;&#x5B9E;&#x65F6;&#x9884;&#x89C8;&#x4E66;&#x7C4D;&#xFF1A;</p>
<pre><code class="lang-bash">gitbook serve
</code></pre>
<p>&#x542F;&#x52A8;&#x6210;&#x529F;&#x540E;&#xFF0C;&#x6253;&#x5F00;&#x6D4F;&#x89C8;&#x5668;&#x8BBF;&#x95EE; <a href="http://localhost:4000/" target="_blank">http://localhost:4000</a> &#x5373;&#x53EF;&#x9884;&#x89C8;&#x4E66;&#x7C4D;&#x3002;</p>
<h3 id="2-&#x6307;&#x5B9A;&#x7AEF;&#x53E3;"><a name="2-&#x6307;&#x5B9A;&#x7AEF;&#x53E3;" class="plugin-anchor" href="#2-&#x6307;&#x5B9A;&#x7AEF;&#x53E3;"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x6307;&#x5B9A;&#x7AEF;&#x53E3;</h3>
<p>&#x5982;&#x679C;&#x9ED8;&#x8BA4;&#x7AEF;&#x53E3;&#x88AB;&#x5360;&#x7528;&#xFF0C;&#x53EF;&#x4EE5;&#x6307;&#x5B9A;&#x5176;&#x4ED6;&#x7AEF;&#x53E3;&#xFF1A;</p>
<pre><code class="lang-bash">gitbook serve --port 3000
</code></pre>
<blockquote>
<p>&#x1F4A1; <strong>&#x63D0;&#x793A;</strong>&#xFF1A;<code>gitbook serve</code> &#x547D;&#x4EE4;&#x4F1A;&#x9996;&#x5148;&#x8C03;&#x7528; <code>gitbook build</code> &#x7F16;&#x8BD1;&#x4E66;&#x7C4D;&#xFF0C;&#x7136;&#x540E;&#x542F;&#x52A8; web &#x670D;&#x52A1;&#x5668;&#x76D1;&#x542C;&#x6307;&#x5B9A;&#x7AEF;&#x53E3;&#x3002;</p>
</blockquote>
<h2 id="&#x6784;&#x5EFA;&#x9759;&#x6001;&#x7F51;&#x7AD9;"><a name="&#x6784;&#x5EFA;&#x9759;&#x6001;&#x7F51;&#x7AD9;" class="plugin-anchor" href="#&#x6784;&#x5EFA;&#x9759;&#x6001;&#x7F51;&#x7AD9;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x6784;&#x5EFA;&#x9759;&#x6001;&#x7F51;&#x7AD9;</h2>
<h3 id="1-&#x751F;&#x6210;&#x9759;&#x6001;&#x7F51;&#x9875;"><a name="1-&#x751F;&#x6210;&#x9759;&#x6001;&#x7F51;&#x9875;" class="plugin-anchor" href="#1-&#x751F;&#x6210;&#x9759;&#x6001;&#x7F51;&#x9875;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x751F;&#x6210;&#x9759;&#x6001;&#x7F51;&#x9875;</h3>
<pre><code class="lang-bash">gitbook build
</code></pre>
<p>&#x9ED8;&#x8BA4;&#x60C5;&#x51B5;&#x4E0B;&#xFF0C;&#x751F;&#x6210;&#x7684;&#x9759;&#x6001;&#x7F51;&#x7AD9;&#x4F1A;&#x8F93;&#x51FA;&#x5230; <code>_book</code> &#x76EE;&#x5F55;&#x3002;</p>
<h3 id="2-&#x6307;&#x5B9A;&#x8F93;&#x51FA;&#x76EE;&#x5F55;"><a name="2-&#x6307;&#x5B9A;&#x8F93;&#x51FA;&#x76EE;&#x5F55;" class="plugin-anchor" href="#2-&#x6307;&#x5B9A;&#x8F93;&#x51FA;&#x76EE;&#x5F55;"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x6307;&#x5B9A;&#x8F93;&#x51FA;&#x76EE;&#x5F55;</h3>
<pre><code class="lang-bash">gitbook build ./ ./dist
</code></pre>
<h2 id="&#x751F;&#x6210;&#x7535;&#x5B50;&#x4E66;"><a name="&#x751F;&#x6210;&#x7535;&#x5B50;&#x4E66;" class="plugin-anchor" href="#&#x751F;&#x6210;&#x7535;&#x5B50;&#x4E66;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x751F;&#x6210;&#x7535;&#x5B50;&#x4E66;</h2>
<p>GitBook &#x652F;&#x6301;&#x591A;&#x79CD;&#x7535;&#x5B50;&#x4E66;&#x683C;&#x5F0F;&#x8F93;&#x51FA;&#x3002;</p>
<h3 id="1-&#x751F;&#x6210;-pdf"><a name="1-&#x751F;&#x6210;-pdf" class="plugin-anchor" href="#1-&#x751F;&#x6210;-pdf"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x751F;&#x6210; PDF</h3>
<pre><code class="lang-bash">gitbook pdf ./ ./mybook.pdf
</code></pre>
<h3 id="2-&#x751F;&#x6210;-epub"><a name="2-&#x751F;&#x6210;-epub" class="plugin-anchor" href="#2-&#x751F;&#x6210;-epub"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x751F;&#x6210; EPUB</h3>
<pre><code class="lang-bash">gitbook epub ./ ./mybook.epub
</code></pre>
<h3 id="3-&#x751F;&#x6210;-mobi"><a name="3-&#x751F;&#x6210;-mobi" class="plugin-anchor" href="#3-&#x751F;&#x6210;-mobi"><i class="fa fa-link" aria-hidden="true"></i></a>3. &#x751F;&#x6210; MOBI</h3>
<pre><code class="lang-bash">gitbook mobi ./ ./mybook.mobi
</code></pre>
<h3 id="&#x5B89;&#x88C5;-calibre&#xFF08;&#x5FC5;&#x9700;&#xFF09;"><a name="&#x5B89;&#x88C5;-calibre&#xFF08;&#x5FC5;&#x9700;&#xFF09;" class="plugin-anchor" href="#&#x5B89;&#x88C5;-calibre&#xFF08;&#x5FC5;&#x9700;&#xFF09;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x5B89;&#x88C5; Calibre&#xFF08;&#x5FC5;&#x9700;&#xFF09;</h3>
<p>&#x8981;&#x751F;&#x6210; PDF&#x3001;EPUB&#x3001;MOBI &#x683C;&#x5F0F;&#xFF0C;&#x9700;&#x8981;&#x5B89;&#x88C5; <a href="https://calibre-ebook.com/" target="_blank">Calibre</a>&#xFF1A;</p>
<ol>
<li>&#x4E0B;&#x8F7D;&#x5E76;&#x5B89;&#x88C5; Calibre</li>
<li>macOS &#x7528;&#x6237;&#x9700;&#x8981;&#x521B;&#x5EFA;&#x8F6F;&#x94FE;&#x63A5;&#xFF1A;</li>
</ol>
<pre><code class="lang-bash">ln <span class="hljs-_">-s</span> /Applications/calibre.app/Contents/MacOS/ebook-convert /usr/<span class="hljs-built_in">local</span>/bin
</code></pre>
<ol>
<li>Windows &#x7528;&#x6237;&#x786E;&#x4FDD; Calibre &#x5B89;&#x88C5;&#x76EE;&#x5F55;&#x5728;&#x7CFB;&#x7EDF; PATH &#x4E2D;</li>
</ol>
<h2 id="&#x7248;&#x672C;&#x7BA1;&#x7406;"><a name="&#x7248;&#x672C;&#x7BA1;&#x7406;" class="plugin-anchor" href="#&#x7248;&#x672C;&#x7BA1;&#x7406;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x7248;&#x672C;&#x7BA1;&#x7406;</h2>
<h3 id="1-&#x67E5;&#x770B;&#x672C;&#x5730;&#x5B89;&#x88C5;&#x7684;&#x7248;&#x672C;"><a name="1-&#x67E5;&#x770B;&#x672C;&#x5730;&#x5B89;&#x88C5;&#x7684;&#x7248;&#x672C;" class="plugin-anchor" href="#1-&#x67E5;&#x770B;&#x672C;&#x5730;&#x5B89;&#x88C5;&#x7684;&#x7248;&#x672C;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x67E5;&#x770B;&#x672C;&#x5730;&#x5B89;&#x88C5;&#x7684;&#x7248;&#x672C;</h3>
<pre><code class="lang-bash">gitbook ls
</code></pre>
<h3 id="2-&#x67E5;&#x770B;&#x8FDC;&#x7A0B;&#x53EF;&#x7528;&#x7248;&#x672C;"><a name="2-&#x67E5;&#x770B;&#x8FDC;&#x7A0B;&#x53EF;&#x7528;&#x7248;&#x672C;" class="plugin-anchor" href="#2-&#x67E5;&#x770B;&#x8FDC;&#x7A0B;&#x53EF;&#x7528;&#x7248;&#x672C;"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x67E5;&#x770B;&#x8FDC;&#x7A0B;&#x53EF;&#x7528;&#x7248;&#x672C;</h3>
<pre><code class="lang-bash">gitbook ls-remote
</code></pre>
<h3 id="3-&#x5B89;&#x88C5;&#x6307;&#x5B9A;&#x7248;&#x672C;"><a name="3-&#x5B89;&#x88C5;&#x6307;&#x5B9A;&#x7248;&#x672C;" class="plugin-anchor" href="#3-&#x5B89;&#x88C5;&#x6307;&#x5B9A;&#x7248;&#x672C;"><i class="fa fa-link" aria-hidden="true"></i></a>3. &#x5B89;&#x88C5;&#x6307;&#x5B9A;&#x7248;&#x672C;</h3>
<pre><code class="lang-bash">gitbook fetch 2.6.7
</code></pre>
<h3 id="4-&#x4F7F;&#x7528;&#x6307;&#x5B9A;&#x7248;&#x672C;&#x6784;&#x5EFA;"><a name="4-&#x4F7F;&#x7528;&#x6307;&#x5B9A;&#x7248;&#x672C;&#x6784;&#x5EFA;" class="plugin-anchor" href="#4-&#x4F7F;&#x7528;&#x6307;&#x5B9A;&#x7248;&#x672C;&#x6784;&#x5EFA;"><i class="fa fa-link" aria-hidden="true"></i></a>4. &#x4F7F;&#x7528;&#x6307;&#x5B9A;&#x7248;&#x672C;&#x6784;&#x5EFA;</h3>
<pre><code class="lang-bash">gitbook build --gitbook=2.6.7
</code></pre>
<h3 id="5-&#x66F4;&#x65B0;&#x5230;&#x6700;&#x65B0;&#x7248;&#x672C;"><a name="5-&#x66F4;&#x65B0;&#x5230;&#x6700;&#x65B0;&#x7248;&#x672C;" class="plugin-anchor" href="#5-&#x66F4;&#x65B0;&#x5230;&#x6700;&#x65B0;&#x7248;&#x672C;"><i class="fa fa-link" aria-hidden="true"></i></a>5. &#x66F4;&#x65B0;&#x5230;&#x6700;&#x65B0;&#x7248;&#x672C;</h3>
<pre><code class="lang-bash">gitbook update
</code></pre>
<h3 id="6-&#x5378;&#x8F7D;&#x6307;&#x5B9A;&#x7248;&#x672C;"><a name="6-&#x5378;&#x8F7D;&#x6307;&#x5B9A;&#x7248;&#x672C;" class="plugin-anchor" href="#6-&#x5378;&#x8F7D;&#x6307;&#x5B9A;&#x7248;&#x672C;"><i class="fa fa-link" aria-hidden="true"></i></a>6. &#x5378;&#x8F7D;&#x6307;&#x5B9A;&#x7248;&#x672C;</h3>
<pre><code class="lang-bash">gitbook uninstall 2.6.7
</code></pre>
<h2 id="&#x8C03;&#x8BD5;&#x548C;&#x6545;&#x969C;&#x6392;&#x9664;"><a name="&#x8C03;&#x8BD5;&#x548C;&#x6545;&#x969C;&#x6392;&#x9664;" class="plugin-anchor" href="#&#x8C03;&#x8BD5;&#x548C;&#x6545;&#x969C;&#x6392;&#x9664;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x8C03;&#x8BD5;&#x548C;&#x6545;&#x969C;&#x6392;&#x9664;</h2>
<h3 id="1-&#x8C03;&#x8BD5;&#x6A21;&#x5F0F;"><a name="1-&#x8C03;&#x8BD5;&#x6A21;&#x5F0F;" class="plugin-anchor" href="#1-&#x8C03;&#x8BD5;&#x6A21;&#x5F0F;"><i class="fa fa-link" aria-hidden="true"></i></a>1. &#x8C03;&#x8BD5;&#x6A21;&#x5F0F;</h3>
<p>&#x83B7;&#x53D6;&#x8BE6;&#x7EC6;&#x7684;&#x8C03;&#x8BD5;&#x4FE1;&#x606F;&#xFF1A;</p>
<pre><code class="lang-bash">gitbook build --log=debug --debug
</code></pre>
<h3 id="2-&#x67E5;&#x770B;&#x5E2E;&#x52A9;&#x4FE1;&#x606F;"><a name="2-&#x67E5;&#x770B;&#x5E2E;&#x52A9;&#x4FE1;&#x606F;" class="plugin-anchor" href="#2-&#x67E5;&#x770B;&#x5E2E;&#x52A9;&#x4FE1;&#x606F;"><i class="fa fa-link" aria-hidden="true"></i></a>2. &#x67E5;&#x770B;&#x5E2E;&#x52A9;&#x4FE1;&#x606F;</h3>
<pre><code class="lang-bash">gitbook --help
</code></pre>
<h3 id="3-&#x5E38;&#x89C1;&#x95EE;&#x9898;"><a name="3-&#x5E38;&#x89C1;&#x95EE;&#x9898;" class="plugin-anchor" href="#3-&#x5E38;&#x89C1;&#x95EE;&#x9898;"><i class="fa fa-link" aria-hidden="true"></i></a>3. &#x5E38;&#x89C1;&#x95EE;&#x9898;</h3>
<p>&#x5982;&#x679C;&#x9047;&#x5230;&#x6784;&#x5EFA;&#x9519;&#x8BEF;&#xFF0C;&#x53EF;&#x4EE5;&#x5C1D;&#x8BD5;&#xFF1A;</p>
<ol>
<li><strong>&#x6E05;&#x7406;&#x7F13;&#x5B58;</strong>&#xFF1A;&#x5220;&#x9664; <code>_book</code> &#x76EE;&#x5F55;</li>
<li><strong>&#x91CD;&#x65B0;&#x5B89;&#x88C5;</strong>&#xFF1A;&#x5378;&#x8F7D;&#x5E76;&#x91CD;&#x65B0;&#x5B89;&#x88C5; gitbook-cli</li>
<li><strong>&#x68C0;&#x67E5;&#x7248;&#x672C;</strong>&#xFF1A;&#x786E;&#x4FDD;&#x4F7F;&#x7528;&#x517C;&#x5BB9;&#x7684; Node.js &#x7248;&#x672C;</li>
</ol>
<h2 id="&#x547D;&#x4EE4;&#x901F;&#x67E5;&#x8868;"><a name="&#x547D;&#x4EE4;&#x901F;&#x67E5;&#x8868;" class="plugin-anchor" href="#&#x547D;&#x4EE4;&#x901F;&#x67E5;&#x8868;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x547D;&#x4EE4;&#x901F;&#x67E5;&#x8868;</h2>
<table>
<thead>
<tr>
<th>&#x547D;&#x4EE4;</th>
<th>&#x529F;&#x80FD;</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>gitbook init</code></td>
<td>&#x521D;&#x59CB;&#x5316;&#x4E66;&#x7C4D;</td>
</tr>
<tr>
<td><code>gitbook serve</code></td>
<td>&#x542F;&#x52A8;&#x672C;&#x5730;&#x670D;&#x52A1;</td>
</tr>
<tr>
<td><code>gitbook build</code></td>
<td>&#x6784;&#x5EFA;&#x9759;&#x6001;&#x7F51;&#x7AD9;</td>
</tr>
<tr>
<td><code>gitbook pdf</code></td>
<td>&#x751F;&#x6210; PDF</td>
</tr>
<tr>
<td><code>gitbook epub</code></td>
<td>&#x751F;&#x6210; EPUB</td>
</tr>
<tr>
<td><code>gitbook mobi</code></td>
<td>&#x751F;&#x6210; MOBI</td>
</tr>
<tr>
<td><code>gitbook ls</code></td>
<td>&#x67E5;&#x770B;&#x672C;&#x5730;&#x7248;&#x672C;</td>
</tr>
<tr>
<td><code>gitbook --help</code></td>
<td>&#x67E5;&#x770B;&#x5E2E;&#x52A9;</td>
</tr>
</tbody>
</table>
<h2 id="&#x4E0B;&#x4E00;&#x6B65;"><a name="&#x4E0B;&#x4E00;&#x6B65;" class="plugin-anchor" href="#&#x4E0B;&#x4E00;&#x6B65;"><i class="fa fa-link" aria-hidden="true"></i></a>&#x4E0B;&#x4E00;&#x6B65;</h2>
<p>&#x73B0;&#x5728;&#x4F60;&#x5DF2;&#x7ECF;&#x638C;&#x63E1;&#x4E86; GitBook &#x7684;&#x57FA;&#x672C;&#x4F7F;&#x7528;&#x65B9;&#x6CD5;&#xFF0C;&#x53EF;&#x4EE5;&#xFF1A;</p>
<ol>
<li>&#x5B66;&#x4E60;&#x5982;&#x4F55;<a href="&#x4FEE;&#x6539;gitbook&#x5185;&#x5BB9;&#x5B57;&#x4F53;&#x5927;&#x5C0F;.md">&#x8BBE;&#x7F6E;&#x5B57;&#x4F53;&#x5927;&#x5C0F;</a></li>
<li>&#x4E86;&#x89E3;&#x66F4;&#x591A;<a href="../&#x63D2;&#x4EF6;&#x5B89;&#x88C5;.html">&#x63D2;&#x4EF6;&#x63A8;&#x8350;</a></li>
<li>&#x63A2;&#x7D22;<a href="../Gitbook&#x4E3B;&#x9898;&#x9009;&#x62E9;.html">&#x4E3B;&#x9898;&#x9009;&#x62E9;</a> </li>
</ol>
<footer class="page-footer"><span class="copyright">Copyright &#xA9; 2025 &#x575A;&#x679C;&#x6D3E; all right reserved&#xFF0C;powered by Gitbook</span><span class="footer-modification">&#x6700;&#x540E;&#x4FEE;&#x6539;&#x65F6;&#x95F4;&#xFF1A;
2025-09-09 08:13:03
</span></footer>
<script>console.log("plugin-popup....");document.onclick = function(e){ e.target.tagName === "IMG" && window.open(e.target.src,e.target.src)}</script><style>img{cursor:pointer}</style> 
          </section>
          
    </div>
    <div class="search-results">
        <div class="has-results">
            
            <h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
            <ul class="search-results-list"></ul>
            
        </div>
        <div class="no-results">
            
            <h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
            
        </div>
    </div>
</div>
 
          <div class="book-footer">
            
            <div class="donate">
              <div></div>
              <button class="donate-btn" onclick="showModal()">赞赏</button>
            </div>
             
            <div class="copyright"></div>
            
          </div>
          
        </div>
      </div>
      
    </div>

     
    <a
      href="../安装.html"
      class="
        navigation navigation-prev
        
      "
      aria-label="Previous page: 安装 GitBook"
    >
      <i class="fa fa-angle-left"></i>
    </a>
     
    <a
      href="../修改gitbook内容字体大小.html"
      class="
        navigation navigation-next
        
      "
      aria-label="Next page: 修改字体大小"
    >
      <i class="fa fa-angle-right"></i>
    </a>
      
  </div>
  <script>
    function showModal() {
      document.getElementsByClassName("mask")[0].style.display = "block";
      document.getElementsByClassName("donate-modal")[0].style.display =
        "block";
    }
    // 切换赞赏码
    function showDonateImg(num) {
      let alipay = "";
      let wxpay = ""
      if(num){
        wxpay = "hidden"
      }else{
        alipay = "hidden"
      }
      document.getElementById("wxpay-code").hidden = wxpay;
      document.getElementById("alipay-code").hidden = alipay;
      document.getElementsByName("pay-way")[num].checked = "checked";
    }

    // 关闭赞赏框
    function closeDonateModal() {
      document.getElementsByClassName("mask")[0].style.display = "none";
      document.getElementsByClassName("donate-modal")[0].style.display = "none";
    }

    var gitbook = gitbook || [];
    gitbook.push(function () {
      gitbook.page.hasChanged({"page":{"title":"基本使用","level":"3.3","depth":1,"next":{"title":"修改字体大小","level":"3.3.1","depth":2,"path":"修改gitbook内容字体大小.md","ref":"修改gitbook内容字体大小.md","articles":[]},"previous":{"title":"安装 GitBook","level":"3.2","depth":1,"path":"安装.md","ref":"安装.md","articles":[]},"dir":"ltr"},"config":{"plugins":["github-buttons@2.1.0","edit-link","splitter","tbfed-pagefooter","expandable-chapters","chapter-fold","back-to-top-button","code","pageview-count","popup","search-plus","-lunr","-search","-sharing","sharing-plus","theme-lou","mind-maps","emphasize","anchors","livereload","ace","livereload"],"root":".","styles":{"website":"styles/website.css"},"pluginsConfig":{"tbfed-pagefooter":{"modify_label":"最后修改时间：","modify_format":"YYYY-MM-DD HH:mm:ss","copyright":"Copyright © 2025 坚果派"},"chapter-fold":{},"emphasize":{},"ace":{"theme":"tomorrow","fontSize":14},"livereload":{},"splitter":{},"sharing-plus":{"qq":true,"all":["qq","qzone","twitter","facebook","weibo","pocket","stumbleupon"],"douban":false,"facebook":true,"weibo":true,"instapaper":false,"whatsapp":false,"hatenaBookmark":false,"twitter":true,"messenger":false,"line":false,"vk":false,"pocket":false,"google":false,"viber":false,"stumbleupon":false,"qzone":true,"linkedin":false},"popup":{},"code":{"copyButtons":true},"theme-lou":{"hide-elements":[".summary .gitbook-link",".summary .divider"],"color":"#2196F3","book-anchor-title":"本页目录","copyright":{"author":"坚果派"},"forbidCopy":false,"logo":"assets/logo.png","book-summary-title":"目录","search-placeholder":"搜索关键字...","copyrightLogo":"assets/copyright.png","favicon":"assets/favicon.ico","appleTouchIconPrecomposed152":"assets/avatar.png"},"fontsettings":{"theme":"white","family":"sans","size":2},"mind-maps":{},"highlight":{},"back-to-top-button":{},"pageview-count":{},"github-buttons":{},"sharing":{},"edit-link":{"label":"编辑此页","base":"https://gitcode.com/nutpi/gitbook/edit/master/"},"theme-default":{"styles":{"pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css","website":"styles/website.css"},"showLevel":false},"anchors":{},"expandable-chapters":{},"search-plus":{}},"theme":"default","author":"nutpi","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"isbn":"978-0-000000-00-0","variables":{"themeLou":{"nav":[{"target":"_blank","url":"https://www.gitbook.com/","name":"GitBook 官网"},{"target":"_blank","url":"https://www.npmjs.com/search?q=gitbook-plugin","name":"插件市场"},{"target":"_blank","url":"https://space.bilibili.com/480883651","name":"哔哩哔哩"},{"target":"_blank","url":"https://gitcode.com/nutpi","name":"GitCode"}],"footer":{"donate":{"wechat":"https://luckly007.oss-cn-beijing.aliyuncs.com/img/image-20210922202901895.png","message":"如果本教程对你有帮助，欢迎请作者喝杯咖啡 ☕","alipay":"https://luckly007.oss-cn-beijing.aliyuncs.com/img/image-20210922202843746.png","nickname":"Breeze","button":"赞助","wechatText":"微信","alipayText":"支付宝","title":"『赠人玫瑰手有余香』","avatar":"assets/avatar.png"},"copyright":true}}},"title":"GitBook教程","language":"zh-hans","gitbook":"*","description":"GitBook电子书教程-从入门到精通"},"file":{"path":"基本使用/README.md","mtime":"2025-09-09T00:13:03.825Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2025-09-09T13:30:16.506Z"},"basePath":"..","book":{"language":""}});
    });
  </script>
</div>

        
    <script src="../gitbook/gitbook.js"></script>
    <script src="../gitbook/theme.js"></script>
    
        
        <script src="../gitbook/gitbook-plugin-github-buttons/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-edit-link/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-splitter/splitter.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-expandable-chapters/expandable-chapters.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-chapter-fold/chapter-fold.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-back-to-top-button/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-code/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-pageview-count/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search-plus/jquery.mark.min.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search-plus/search.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-sharing-plus/buttons.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-mind-maps/mindmaps.dist.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-livereload/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-ace/ace/ace.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-ace/ace.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-theme-lou/lou.js"></script>
        
    

    </body>
</html>

